home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_10_10
/
1010025b
< prev
next >
Wrap
Text File
|
1992-08-08
|
241b
|
19 lines
#include <stdio.h>
#define MAXLINE 80
main()
{
char bin[MAXLINE+1];
int n, nargs = scanf("%[01]%d",bin,&n);
printf("nargs: %d, bin: %s, n: %d\n",nargs,bin,n);
return 0;
}
Input
1011035
Output
nargs: 2, bin: 10110, n: 35